<?php
header('Content-Type: text/html;charset=UTF-8');
$photolist = '';
$photorows = Db::getRows('*', 'photo');
foreach ($photorows as $photorow) {
    $photolist .= '<div class="photoslist">
                    <a class="light" href="upload/'.$photorow['name'].'"><img src="upload/'.$photorow['name'].'"></a>
            </div>';
}
$photolist = $photolist == '' ? 'Chưa có ảnh': $photolist;
?>